package com.h3bpm.kumhosunny.comment.beans;

import OThinker.Common.Data.Database.Serialization.PropertySerializeMethod;
import OThinker.Common.Data.Database.Serialization.SerializableObject;
import OThinker.Common.EntityInfo;
import OThinker.Common.FieldInfo;
import com.alibaba.fastjson.annotation.JSONField;
import com.fasterxml.jackson.annotation.JsonIgnore;

import java.io.Serializable;
import java.util.Date;

/**
 * @author qinyt
 * @date 2019/02/28
 */
@EntityInfo(
        tableName = "OT_WorkflowCommentAttachment",
        indexs = "",
        isChild = false
)
public class WorkflowCommentAttachment extends SerializableObject implements Serializable {
    private static final long serialVersionUID = 1L;
    public static final String TableName = "OT_WorkflowCommentAttachment";
    public static final String PropertyName_WorkflowCommentID = "WorkflowCommentID";
    @FieldInfo(
            ColumName = "WorkflowCommentID",
            instance = true,
            serializeMethod = PropertySerializeMethod.ForeignKey,
            length = 0
    )
    private String _WorkflowCommentID;
    public static final String PropertyName_Content = "Content";
    @FieldInfo(
            ColumName = "Content",
            instance = true,
            serializeMethod = PropertySerializeMethod.Other,
            length = 0
    )
    private byte[] _Content;
    public static final String PropertyName_ContentType = "ContentType";
    @FieldInfo(
            ColumName = "ContentType",
            instance = true,
            serializeMethod = PropertySerializeMethod.Other,
            length = 0
    )
    private String _ContentType = null;
    public static final String PropertyName_ContentLength = "ContentLength";
    @FieldInfo(
            ColumName = "ContentLength",
            instance = true,
            serializeMethod = PropertySerializeMethod.Other,
            length = 0
    )
    private long _ContentLength = 0L;
    public static final String PropertyName_FileName = "FileName";
    @FieldInfo(
            ColumName = "FileName",
            instance = true,
            serializeMethod = PropertySerializeMethod.Other,
            length = 0
    )
    private String _FileName = null;
    public static final String PropertyName_Description = "Description";
    @FieldInfo(
            ColumName = "Description",
            instance = true,
            serializeMethod = PropertySerializeMethod.Other,
            length = 1000
    )
    private String _Description = null;
    public static final String PropertyName_Display = "Display";
    @FieldInfo(
            ColumName = "Display",
            instance = true,
            serializeMethod = PropertySerializeMethod.Other,
            length = 0
    )
    private boolean _Display = false;
    public static final String PropertyName_Extension = "Extension";
    @FieldInfo(
            ColumName = "Extension",
            instance = true,
            serializeMethod = PropertySerializeMethod.Other,
            length = 1000
    )
    private String _Extension = null;
    public static final String PropertyName_Url = "Url";
    @FieldInfo(
            ColumName = "Url",
            instance = true,
            serializeMethod = PropertySerializeMethod.Other,
            length = 1000
    )
    private String _Url = null;
    public static final String PropertyName_CreatedTime = "CreatedTime";
    @FieldInfo(
            ColumName = "CreatedTime",
            instance = true,
            serializeMethod = PropertySerializeMethod.Other,
            length = 0
    )
    private Date _CreatedTime = new Date();
    public static final String PropertyName_ModifiedTime = "ModifiedTime";
    @FieldInfo(
            ColumName = "ModifiedTime",
            instance = true,
            serializeMethod = PropertySerializeMethod.Other,
            length = 0
    )
    private Date _ModifiedTime = new Date();

    public WorkflowCommentAttachment() {
    }

    public final String getWorkflowCommentAttachmentID() {
        return this.getObjectID();
    }

    public String getWorkflowCommentID() {
        return this._WorkflowCommentID;
    }

    public void setWorkflowCommentID(String _WorkflowCommentID) {
        this._WorkflowCommentID = _WorkflowCommentID;
    }

    public final byte[] getContent() {
        return this._Content;
    }

    public final void setContent(byte[] value) {
        this._Content = value;
        if (value != null) {
            this.setContentLength((long)value.length);
        }

        this.SetPropertyDirty("Content");
        this.setModifiedTime(new Date());
    }

    public final String getContentType() {
        return this._ContentType;
    }

    public final void setContentType(String value) {
        if (this._ContentType == null || !this._ContentType.equals(value)) {
            this._ContentType = value;
            this.SetPropertyDirty("ContentType");
        }

    }

    public final long getContentLength() {
        return this._ContentLength;
    }

    public final void setContentLength(long value) {
        if (this._ContentLength != value) {
            this._ContentLength = value;
            this.SetPropertyDirty("ContentLength");
        }

    }

    public final String getFileName() {
        return this._FileName;
    }

    public final void setFileName(String value) {
        if (this._FileName == null || !this._FileName.equals(value)) {
            this._FileName = value;
            this.SetPropertyDirty("FileName");
        }

    }

    public final String getDescription() {
        return this._FileName;
    }

    public final void setDescription(String value) {
        if (this._Description == null || !this._Description.equals(value)) {
            this._Description = value;
            this.SetPropertyDirty("Description");
        }

    }

    public final boolean getDisplay() {
        return this._Display;
    }

    public final void setDisplay(boolean value) {
        if (this._Display != value) {
            this._Display = value;
            this.SetPropertyDirty("Display");
        }

    }

    public final String getExtension() {
        return this._Extension;
    }

    public final void setExtension(String value) {
        if (this._Extension == null || !this._Extension.equals(value)) {
            this._Extension = value;
            this.SetPropertyDirty("Extension");
        }

    }

    public final String getUrl() {
        return this._Url;
    }

    public final void setUrl(String value) {
        if (this._Url == null || !this._Url.equals(value)) {
            this._Url = value;
            this.SetPropertyDirty("Url");
        }

    }

    public final Date getCreatedTime() {
        return this._CreatedTime;
    }

    public final void setCreatedTime(Date value) {
        this._CreatedTime = value;
    }

    public final Date getModifiedTime() {
        return this._ModifiedTime;
    }

    public final void setModifiedTime(Date value) {
        if (this._ModifiedTime == null || !this._ModifiedTime.equals(value)) {
            this._ModifiedTime = value;
            this.SetPropertyDirty("ModifiedTime");
        }

    }
}
